<html>
<head>
    <meta charset="UTF-8">
    <title>list</title>
    <script type="text/javascript" src="/static/jquery.min.js" charset="UTF-8"></script>
    <style type="text/css">
        body {
            margin: 0;
            padding: 0px;
            font-family: "Microsoft YaHei", YaHei, "微软雅黑", SimHei, "黑体";
            font-size: 18px;
        }
        p{
            padding-left: 2em;
        }
        .list{
            font-size: 50px;
        }
    </style>
</head>
<body>
    <div class="list">
        {{range .}}
            <a href="./play?file={{.}}">{{.}}</a><br/> <a onclick="myclick({{.}})">删除</a><br/>
        {{end}}
    </div>
</body>
<script type="text/javascript">
    function myclick(file){
        var r=confirm("确定删除该文件")
        if (r===true)
        {
            $.get("./del?file="+file,function(data,status){
                alert("msg: " + data + "\nStatus: " + status);
                location.reload();
            });
        }
    }
</script>
</html>